<template>
	<view class="photo-box">
		<scroll-view scroll-x>
			<view class="scroll-box">
				<view class="img-box" @click="showImage(item)" v-for="(item,index) in dataList">
					<uv-image border-radius="20" width="170rpx" height="170rpx" :src="item"></uv-image>
				</view>
			</view>
		</scroll-view>
	</view>
</template>

<script>
	export default {
		components: {
			
		},
		props: {
			dataList: {
				type: Array,
				default: [],
			},
		},
		data() {
			return {
				
			}
		},
		methods: {
			showImage(src) {
				uni.previewImage({
					indicator: "none",
					current: src,
					urls: this.dataList,
				});
			},
		}
	}
</script>

<style lang="scss" scoped>
	.photo-box {
		.scroll-box {
			display: flex;
		}
		.img-box {
			margin-right: 15px;
		}
	}
</style>